package com.lhy.mymall.service;

import com.lhy.mymall.exception.MallException;
import com.lhy.mymall.vo.CartVO;

import java.util.List;

/**
 * @author: 卢辉宇
 * @date: 2022/12/18 11:46
 * @description:
 */
public interface CartService {

    List<CartVO> list(Integer userId);

    List<CartVO> add(Integer userId, Integer productId, Integer count) throws MallException;

    List<CartVO> update(Integer userId, Integer productId, Integer count) throws MallException;

    List<CartVO> delete(Integer userId, Integer productId) throws MallException;

    List<CartVO> selectOrNot(Integer userId, Integer productId, Integer selected) throws MallException;

    List<CartVO> selectAllOrNot(Integer userId, Integer selected);
}
